-- GENERATED SPELL FOR [Storm Bay Oracle] --


function spell0_6351(pUnit, Event) --@Heal,Heal--
pUnit:FullCastSpellOnTarget(11642,pUnit)
pUnit:RegisterEvent('Sorts_6351', 3500, 1)
end

function spell1_6351(pUnit, Event) --@Lightning Bolt,n/a--
pUnit:FullCastSpellOnTarget(9532,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6351', 3000, 1)
end

function Sorts_6351(pUnit, Event)
local choix_sorts_6351 = math.random(0, 1)
if choix_sorts_6351 == 0 then
pUnit:RegisterEvent('spell0_6351', 1, 1)
end
if choix_sorts_6351 == 1 then
pUnit:RegisterEvent('spell1_6351', 1, 1)
end
end

function mob6351_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_6351', math.random(1500, 3000), 1)
end

function mob6351_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6351_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6351_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(6351, 1, 'mob6351_Action')
RegisterUnitEvent(6351, 2, 'mob6351_Leave')
RegisterUnitEvent(6351, 3, 'mob6351_Kill')
RegisterUnitEvent(6351, 4, 'mob6351_Die')
